#region History

/* --------------------------------------------------------------------------------
 * Client Name: Bd Market Ltd.
 * Project Name: BdMarket
 * Module: RH.Web.ViewModels 
 * Name: Category.cs
 * Purpose: ViewModel class for Category
 *                   
 * Author: Md. Hassanur Rahman
 * Language: C# SDK Version 4.0
 * --------------------------------------------------------------------------------
 * Change History:
 * Version: 1.0    MHR  01/21/2012
 * Description: Initial Development
 * -------------------------------------------------------------------------------- */

#endregion

using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.ComponentModel.DataAnnotations;
using System.Web.Mvc;


namespace RH.Web.ViewModels
{
    [Serializable]
	public class CategoryViewModel : BaseViewModel
	{	
        /// <summary>
		/// Gets or sets the ID
		/// </summary>
        public int ID { get; set;}
            
        [Required(ErrorMessage= "Please Enter a Name")]
        [StringLength(100, ErrorMessage = "The {0} can be maximum {1} characters long.")]
        [Display(Name = "Name")] 
		public String Name	{ get; set; }
        
        [Display(Name = "Parent Category")]        
        public int? ParentID { get; set;}

        [Display(Name = "ZGL Model")]
        public int? ZGLID { get; set; }
            
        [StringLength(500, ErrorMessage = "The {0} can be maximum {1} characters long.")]
        [Display(Name = "Description")] 
		public String Description	{ get; set; }
            
        //[Display(Name = "Property Definition")]
        //[AllowHtml]
        //public String PropertyDefinition	{ get; set; }

        public String UrlName { get; set; }
        public CategoryViewModel ParentCategory { get; set; }

        public List<CategoryViewModel> ChildCategories { get; set; }
        public ZGLViewModel ZGL { get; set; }

        //[Required(ErrorMessage = "Please Enter a Created On")]
        //[Display(Name = "Created On")]
        //public String CreatedOn { get; set; }

        //[Required(ErrorMessage = "Please Enter a Createb By")]
        //[Display(Name = "Createb By")]
        //public String CreatebBy { get; set; }

        //[Required(ErrorMessage = "Please Enter a Modified On")]
        //[Display(Name = "Modified On")]
        //public String ModifiedOn { get; set; }

        //[Required(ErrorMessage = "Please Select a Modified By")]
        //[Display(Name = "Modified By")]
        //public int ModifiedBy { get; set; }
	}
}

